[#11094] feat(client-python): add Group authorization management#11109
Conversation
|
@jerryshao Could you help review this PR? Thanks a lot. |
Code Coverage Report
Files
|
|
@jerryshao Looks like Copilot failed, could you retrigger it? |
f1427ff to
22317a4
Compare
Add Group entity support to the Python SDK, including: - Group API interface and GroupDTO with immutable roles - GroupAddRequest, GroupResponse, GroupListResponse, GroupNamesListResponse - GroupErrorHandler for REST error mapping - GravitinoMetalake group CRUD methods (add/remove/get/list/list_names) - GravitinoClient delegate methods - Unit tests and integration tests
… integration tests
Fix setUpClass to always modify gravitino.conf and restart the server when running under Gradle (START_EXTERNAL_GRAVITINO=true). Add tearDownClass to restore the config after tests.
…k in GroupDTO builder
…auth - Remove test_builder_no_audit_raises to match relaxed GroupDTO builder - Add unit test for GroupAddRequest - Add serviceAdmins config in group integration test
22317a4 to
ce1b20c
Compare
|
@jerryshao The PythonIT failure in the latest run seems to be a CI environment issue — the Gravitino server failed to start ( |
|
The IT still fails. Maybe you can download the log here https://github.com/apache/gravitino/actions/runs/26163265995?pr=11109 and investigate it locally. |
…config - Fix test_group_management tearDown to properly restore auth config - Fix test_user setUp to include serviceAdmins and tearDown to restore config - Format test_owner with black
|
@jerryshao The CI has passed now. The root cause of the previous IT failure was that |
Summary
This PR adds Group authorization management support to the Gravitino Python client SDK, following the pattern established in #11058 (User management). It is split from the original monolithic PR #10783.
Changes
Groupinterface withname()androles()methodsGroupDTOwith immutable roles (tuple[str, ...]internally, defensivelistcopy viaroles()); audit null validation in BuilderGroupAddRequest,GroupResponse,GroupListResponse,GroupNamesListResponseGroupErrorHandlermapping REST error codes toNoSuchGroupException,GroupAlreadyExistsException, etc.GravitinoMetalakeandGravitinoClient(add_group,remove_group,get_group,list_groups,list_group_names)Sub-task of
Related issues
Reviewers
@jerryshao